home *** CD-ROM | disk | FTP | other *** search
/ PC/CD Review 17 / PC Review Disc 17.ISO / tclite / install.bat next >
Encoding:
DOS Batch File  |  1995-09-19  |  2.9 KB  |  127 lines

  1. @echo off
  2.  
  3. :Initialize
  4.   @echo.
  5.   @echo.
  6.   @echo.
  7.   @echo.
  8.   @echo.
  9.   @echo              BORLAND TCLITE INSTALLATION
  10.   @echo    Copyright (c) 1994 by Borland International, Inc
  11.   @echo.
  12.   @echo.
  13.   @echo.
  14.   @echo.
  15.   if "%1"=="" goto Usage1
  16.   if not "%INSTALL%"==""  set OLD_INST=%INSTALL%
  17.   if not "%INST_DRV%"=="" set OLD_DRV=%INST_DRV%
  18.   set INST_DRV=%1
  19.   set INSTALL=%INST_DRV%
  20.   set INSTALL=%INSTALL%\TCLITE
  21.   if not exist unzip.exe goto Usage
  22.  
  23. :Check_for_existance
  24.   if exist %INSTALL%\*.* set INSTALL=%INST_DRV%\TCLITEXX
  25.   if exist %INSTALL%\*.* goto Overwrite?
  26.   md %INSTALL%
  27.  
  28. :Install_It
  29.   @echo.
  30.   @echo.
  31.   @echo.
  32.   @echo Installing into %INSTALL% please wait.....
  33.   @echo.
  34.   @echo.
  35.   unzip -d tclite.zip %INSTALL% >nul
  36.   if errorlevel 1 goto Busted
  37.   copy readme %INSTALL% >nul
  38.   copy readme.com %INSTALL% >nul
  39.   if not exist %INSTALL%\readme.com goto Busted
  40.  
  41. :All_Done
  42.   @del c:\autoexec.pcr
  43.   @copy c:\autoexec.bat c:\autoexec.pcr >nul
  44.   @echo. >>c:\autoexec.bat
  45.   @echo REM ** The following line was added by the TCLITE installer ** >>c:\autoexec.bat
  46.   @echo PATH=%%path%%;%INSTALL%\BIN; >>c:\autoexec.bat
  47.   @cls
  48.   @echo.
  49.   @echo.
  50.   @echo.
  51.   @echo.
  52.   @echo.
  53.   @echo             BORLAND TCLITE SUCCESSFULLY INSTALLED
  54.   @echo.
  55.   @echo Your AUTOEXEC.BAT has been modified and your old file has been
  56.   @echo saved as AUTOEXEC.PCR. Please reboot for changes to take effect.
  57.   @echo.
  58.   @echo      Refer to %INSTALL%\readme for additional information.
  59.   @echo.
  60.   @echo.
  61.   @echo.
  62.   @echo.
  63.   goto End
  64.  
  65.  
  66.  
  67. :Busted
  68.   @echo.
  69.   @echo.
  70.   @echo.
  71.   @echo  An error occured during the installation.  Check
  72.   @echo  that there is at least 2Mbtes of free space on %INST_DRV% to
  73.   @echo  install this product and try again.
  74.   @echo.
  75.   @echo.
  76.   goto End
  77.   
  78. :Overwrite?
  79.   @echo.
  80.   @echo.
  81.   @echo.
  82.   @echo  %INSTALL% already exists.
  83.   @echo.
  84.   @echo.
  85.   @echo  If you DO NOT want to install into %INSTALL% press
  86.   @echo  Crtl Break NOW or any other key to continue the installation
  87.   @echo.
  88.   @echo.
  89.   pause
  90.   goto Install_It
  91.  
  92. :Usage1
  93.   @echo.
  94.   @echo.
  95.   @echo.
  96.   @echo.
  97.   @echo  Usage: install drive_letter
  98.   @echo.
  99.   @echo         drive_letter = target drive letter including colon
  100.   @echo                        (ie C:)
  101.   @echo.
  102.   @echo         You must be on the drive that contains the installation
  103.   @echo         disk to perform this installation (ie A:).
  104.   @echo.
  105.   @echo.
  106.   @echo.
  107.   goto End
  108.   
  109. :Usage
  110.   @echo.
  111.   @echo.
  112.   @echo.
  113.   @echo.
  114.   @echo  You must change to the drive that contains the installation disk
  115.   @echo  do perform this installation. For example, if the installation
  116.   @echo  disk is in your A drive, change to it and then type install.
  117.   @echo.
  118.   @echo.
  119.   @echo.
  120.   goto End
  121.  
  122. :End
  123.   If "%OLD_INST%"=="" set INSTALL=
  124.   If not "%OLD_INST%"=="" set INSTALL=%OLD_INST%
  125.   If "%OLD_DRV%"=="" set INST_DRV=
  126.   If not "%OLD_DRV%"=="" set INST_DRV=%OLD_INST%
  127.